#include <boost/circular_buffer.hpp>
#include <iostream>

int main()
{
	typedef boost::circular_buffer<int> circular_buffer;
	circular_buffer cb(3);

	std::cout << "capacity(): " << cb.capacity() << std::endl;
	std::cout << "size(): " << cb.size() << std::endl;

	cb.push_back(0);
	cb.push_back(1);
	cb.push_back(2);

	std::cout << "size(): " << cb.size() << std::endl;

	cb.push_back(3);
	cb.push_back(4);

	std::cout << "size(): " << cb.size() << std::endl;

	for (circular_buffer::iterator it = cb.begin(); it!= cb.end(); ++it)
		std::cout << *it << std::endl;
}